<template>
  <div class="container">
    <Category title="游戏">
      <template slot-scope="data">
        <ul>
          <li v-for="(item, index) in data.games" :key="index">{{ item }}</li>
        </ul>
      </template>
    </Category>

    <Category title="游戏">
      <template slot-scope="data">
        <ol>
          <li v-for="(item, index) in data.games" :key="index">{{ item }}</li>
        </ol>
      </template>
    </Category>
    <Category title="游戏">
    <!-- 作用域插槽 -->
      <template slot-scope="{games}">
        <h4 style="color: red" v-for="(item, index) in games" :key="index">{{ item }}</h4>
      </template>
    </Category>
  </div>
</template>

<script>
import Category from "@/components/Category";

export default {
  name: "App",

  components: {
    Category,
  },
  mounted() {},
  methods: {},
};
</script>

<style scoped>
.container,
.foot {
  display: flex;
  justify-content: space-around;
}
video {
  width: 100%;
}
h4 {
  text-align: center;
}
</style>
